package org.emf.plugins.tomcatlauncher.server;

import org.emf.plugins.tomcatlauncher.server.KyahRequest.Command;

/**
 * An interface to listen to incoming commands in the Kyah server.
 * <br><br>
 * When a command is received the server will invoke the command listener so that it 
 * take others decisions upon a a command execution.
 */
public interface CommandListener {

    /**
     * When
     * @param channel
     * @return TRUE is expects a subsequent command or FALSE if communication is done.
     * @throws Exception if something unexpected happens.
     */
    public boolean onCommand(Command command) throws Exception;

}
